package com.org.zp.ctrl.more;

import android.os.Bundle;
import android.view.KeyEvent;
import android.view.View;
import android.widget.Button;
import android.widget.TextView;

import com.org.base.ctrl.ActivityTaskManager;
import com.org.base.ctrl.BaseActivity;
import com.org.zp.R;

public class AboutUsActivity extends BaseActivity{
	/** Called when the activity is first created. */

	private TextView company_name;
	private TextView company_web;
	private TextView company_phone;
	private TextView company_fax;
	private TextView company_email;
	private TextView company_address;
	
	private TextView title;
	private Button back_btn;
	private Button enable_btn;
	
	@Override
	public void onCreate(Bundle savedInstanceState) {
		super.onCreate(savedInstanceState);
		setContentView(R.layout.about_us);

		if (!(ActivityTaskManager.getInstance()
				.containsName("AboutCompanyActivity"))) {
			ActivityTaskManager.getInstance().putActivity(
					"AboutCompanyActivity", this);
		}

		init();

	}

	private void init() {
		
		company_name = (TextView) findViewById(R.id.company_about_name);
		
		company_web = (TextView) findViewById(R.id.company_about_web);
		
		company_phone = (TextView) findViewById(R.id.company_about_phone);
		
		company_fax = (TextView) findViewById(R.id.company_about_fax);
		
		company_email = (TextView) findViewById(R.id.company_about_email);
		
		company_address = (TextView) findViewById(R.id.company_about_address);
		
		back_btn = (Button) findViewById(R.id.back);
		enable_btn = (Button) findViewById(R.id.top_right_button);
		enable_btn.setVisibility(View.INVISIBLE);
		back_btn.setText("  返回");
		back_btn.setOnClickListener(new View.OnClickListener() {
			@Override
			public void onClick(View v) {
				ActivityTaskManager.getInstance().removeActivity("MoreActivity");
			}
		});
		title = (TextView) findViewById(R.id.headTitle);
		title.setText("关于我们");

	}

	public boolean onKeyDown(int keyCode, KeyEvent event) {
		if (keyCode == KeyEvent.KEYCODE_BACK) {
			ActivityTaskManager.getInstance().removeActivity("MoreActivity");
			return true;
		}
		return super.onKeyDown(keyCode, event);
	}

}